package cn.ecut.service.impl;

import cn.ecut.dao.AlumniDao;
import cn.ecut.model.Alumni;
import cn.ecut.service.AlumniService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class AlumniServiceimpl implements AlumniService {
    @Autowired
    private AlumniDao alumniDao;

    @Override
    public int addAlumni(Alumni alumni) {
        return alumniDao.addAlumni(alumni);
    }

    @Override
    public List<Alumni> selectAllAlumniByPage(int offset, int num) {
        return alumniDao.selectAllAlumniByPage(offset,num);
    }

    @Override
    public Integer selectAllcount() {
        return alumniDao.selectAllcount();
    }

    @Override
    public Integer uodataalumni(Alumni alumni) {
        return alumniDao.uodataalumni(alumni);
    }

    @Override
    public Integer slectCountByphone(String phone) {
        return alumniDao.slectCountByphone(phone);
    }

    @Override
    public Integer slectCountBymail(String mail) {
        return alumniDao.slectCountBymail(mail);
    }

    @Override
    public Integer deleteAlumni(Integer aid) {
        return alumniDao.deleteAlumni(aid);
    }

    @Override
    public List<Alumni> advanceSelect(String s, int offset, int num) {
        return alumniDao.advanceSelect(s,offset,num);
    }

    @Override
    public int advanceSelectCount(String s) {
        return alumniDao.advanceSelectCount(s);
    }

}
